package work;

/**
 * @TODO
 * @Author xu
 * 2025/2/24
 */
public class Day4_5 {
    public static void main(String[] args) {
        int[][] twoDArray = new int[3][3];
        for (int i = 0; i < twoDArray.length; i++) {
            for (int j = 0; j < twoDArray[i].length; j++) {
                twoDArray[i][j] = i * 3 + j + 1;
            }
        }
        System.out.println("二维数组的值:");
        for (int[] row : twoDArray) {
            for (int value : row) {
                System.out.print(value + " ");
            }
            System.out.println();
        }
    }

}
